{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "<img src=\"https://raw.githubusercontent.com/Qiskit/qiskit-tutorials/master/images/qiskit-heading.png\" alt=\"Note: In order for images to show up in this jupyter notebook you need to select File => Trusted Notebook\" width=\"500 px\" align=\"left\">"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## _*Entanglement*_ \n",
    "\n",
    "\n",
    "The latest version of this notebook is available on https://github.com/qiskit/qiskit-tutorial.\n",
    "\n",
    "***\n",
    "### Contributors\n",
    "Jay Gambetta, Antonio Córcoles, Andrew Cross, Anna Phan\n",
    "\n",
    "\n",
    "### Qiskit Package Versions"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'qiskit': '0.10.3',\n",
       " 'qiskit-terra': '0.8.1',\n",
       " 'qiskit-ignis': '0.1.1',\n",
       " 'qiskit-aer': '0.2.1',\n",
       " 'qiskit-ibmq-provider': '0.2.2',\n",
       " 'qiskit-aqua': '0.5.1'}"
      ]
     },
     "execution_count": 1,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import qiskit\n",
    "qiskit.__qiskit_version__"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Introduction\n",
    "Many people tend to think quantum physics is hard math, but this is not actually true. Quantum concepts are very similar to those seen in the linear algebra classes you may have taken as a freshman in college, or even in high school. The challenge of quantum physics is the necessity to accept counter-intuitive ideas, and its lack of a simple underlying theory. We believe that if you can grasp the following two Principles, you will have a good start: \n",
    "1. A physical system in a definite state can still behave randomly.\n",
    "2. Two systems that are too far apart to influence each other can nevertheless behave in ways that, though individually random, are somehow strongly correlated.\n",
    "\n",
    "In this tutorial, we will be discussing the second of these Principles, the first is discussed in [this other tutorial](superposition.ipynb)."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:21:10.790300Z",
     "start_time": "2018-09-29T01:21:10.782117Z"
    }
   },
   "outputs": [],
   "source": [
    "# useful additional packages \n",
    "import matplotlib.pyplot as plt\n",
    "%matplotlib inline\n",
    "\n",
    "# importing Qiskit\n",
    "from qiskit import QuantumCircuit, QuantumRegister, ClassicalRegister\n",
    "from qiskit import BasicAer, IBMQ, execute\n",
    "\n",
    "# import basic plot tools\n",
    "from qiskit.tools.visualization import plot_histogram"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:28.659863Z",
     "start_time": "2018-09-29T01:22:28.657315Z"
    }
   },
   "outputs": [],
   "source": [
    "backend = BasicAer.get_backend('qasm_simulator') # run on local simulator by default\n",
    "\n",
    "# Uncomment the following lines to run on a real device\n",
    "# IBMQ.load_account()\n",
    "# from qiskit.providers.ibmq import least_busy\n",
    "# backend = least_busy(IBMQ.backends(operational=True, simulator=False))\n",
    "# print(\"the best backend is \" + backend.name())"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Entanglement<a id='section2'></a>\n",
    "\n",
    "The core idea behind the second Principle is *entanglement*. Upon reading the Principle, one might be inclined to think that entanglement is simply strong correlation between two entitities -- but entanglement goes well beyond mere perfect (classical) correlation. If you and I read the same paper, we will have learned the same information. If a third person comes along and reads the same paper they <i>also</i> will have learned this information. All three persons in this case are perfectly correlated, and they will remain correlated even if they are separated from each other. \n",
    "\n",
    "The situation with quantum entanglement is a bit more subtle. In the quantum world, you and I could read the same quantum paper, and yet we will not learn what information is actually contained in the paper until we get together and share our information. However, when we are together, we find that we can unlock more information from the paper than we initially thought possible. Thus, quantum entanglement goes much further than perfect correlation.\n",
    "\n",
    "To demonstrate this, we will define the controlled-NOT (CNOT) gate and the composition of two systems. The convention we use Qiskit is to label states by writing the first qubit's name in the rightmost position, thereby allowing us to easily convert from binary to decimal. As a result, we define the tensor product between operators $q_0$ and $q_1$ by $q_1\\otimes q_0$. \n",
    "\n",
    "Taking $q_0$ as the control and $q_1$ as the target, the CNOT with this representation is given by\n",
    "\n",
    "$$ CNOT =\\begin{pmatrix} 1 & 0 & 0 & 0\\\\ 0 & 0 & 0 & 1\\\\0& 0& 1 & 0\\\\0 & 1 & 0 & 0 \\end{pmatrix},$$\n",
    "\n",
    "which is non-standard in the quantum community, but more easily connects to classical computing, where the least significant bit (LSB) is typically on the right. An entangled state of the two qubits can be made via an $H$ gate on the control qubit, followed by the CNOT gate. This generates a particular maximally entangled two-qubit state known as a Bell state, named after John Stewart Bell ([learn more about Bell and his contributions to quantum physics and entanglement](https://en.wikipedia.org/wiki/John_Stewart_Bell)). \n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "To explore this, we can prepare an entangled state of two qubits, and then ask questions about the qubit states. The questions we can ask are:\n",
    "* What is the state of the first qubit in the standard basis?\n",
    "* What is the state of the first qubit in the superposition basis?\n",
    "* What is the state of the second qubit in the standard basis?\n",
    "* What is the state of the second qubit in the superposition basis?\n",
    "* What is the state of both qubits in the standard basis?\n",
    "* what is the state of both qubits in the superposition basis?\n",
    "\n",
    "Below is a program with six such circuits for these six questions."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:38.849434Z",
     "start_time": "2018-09-29T01:22:38.834026Z"
    }
   },
   "outputs": [],
   "source": [
    "# Creating registers\n",
    "q2 = QuantumRegister(2)\n",
    "c1 = ClassicalRegister(1)\n",
    "c2 = ClassicalRegister(2)\n",
    "\n",
    "# quantum circuit to make an entangled bell state \n",
    "bell = QuantumCircuit(q2)\n",
    "bell.h(q2[0])\n",
    "bell.cx(q2[0], q2[1])\n",
    "\n",
    "# quantum circuit to measure q0 in the standard basis\n",
    "measureIZ = QuantumCircuit(q2, c1)\n",
    "measureIZ.measure(q2[0], c1[0])\n",
    "bellIZ = bell+measureIZ\n",
    "\n",
    "# quantum circuit to measure q0 in the superposition basis \n",
    "measureIX = QuantumCircuit(q2, c1)\n",
    "measureIX.h(q2[0])\n",
    "measureIX.measure(q2[0], c1[0])\n",
    "bellIX = bell+measureIX\n",
    "\n",
    "# quantum circuit to measure q1 in the standard basis\n",
    "measureZI = QuantumCircuit(q2, c1)\n",
    "measureZI.measure(q2[1], c1[0])\n",
    "bellZI = bell+measureZI\n",
    "\n",
    "# quantum circuit to measure q1 in the superposition basis \n",
    "measureXI = QuantumCircuit(q2, c1)\n",
    "measureXI.h(q2[1])\n",
    "measureXI.measure(q2[1], c1[0])\n",
    "bellXI = bell+measureXI\n",
    "\n",
    "# quantum circuit to measure q in the standard basis \n",
    "measureZZ = QuantumCircuit(q2, c2)\n",
    "measureZZ.measure(q2[0], c2[0])\n",
    "measureZZ.measure(q2[1], c2[1])\n",
    "bellZZ = bell+measureZZ\n",
    "\n",
    "# quantum circuit to measure q in the superposition basis \n",
    "measureXX = QuantumCircuit(q2, c2)\n",
    "measureXX.h(q2[0])\n",
    "measureXX.h(q2[1])\n",
    "measureXX.measure(q2[0], c2[0])\n",
    "measureXX.measure(q2[1], c2[1])\n",
    "bellXX = bell+measureXX"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:40.148814Z",
     "start_time": "2018-09-29T01:22:38.852125Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAUwAAACkCAYAAAD8DhcEAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAUW0lEQVR4nO3df1DT9/0H8GeibhmYEASK1QAWEKd2gYCML9YZpVrqxEKltNeeWuYstv7hOZ2Fu26undYG1KtutlupG7gBO1lbD9eutrdJ2dUqx0Rxeuet/Fbn9xRKGn4575L3948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tbTwkJ5oYRjva86sv37BarcjIyMCZM2fQ39+PjIwMj53DJCIai199vZter8e2bduwbNkyAMCBAwcYlkSkGL/awyQi8iXunhERSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUn6P3oDyI6hj3G/AAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 421.4x198.66 with 1 Axes>"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bellIZ.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:41.366322Z",
     "start_time": "2018-09-29T01:22:40.151424Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAACkCAYAAACZ4+V7AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAU2UlEQVR4nO3dfUxUZ74H8O8M9krBGYYOiFJEF6it1gLjyKUodaiixIiLW4LusmKJWtjaxLhaC0m3pq2WHdBG2da0JXahCZJK47a4a6t1V0q2FqdEFFf3j4q8iWWvhTCdEUF3h3P/8DLXKW8zMq8P309yksmZ55zfj0f8cnjmzCCTJEkCEREJS+7pBoiIyLUY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9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noiIHMfLYSIiwTHoiYgEx6AnIhIcg56ISHAMeiIiwTHoiYgEx6AnIhIcg56ISHAMeiIiwTHoiYgEx6AnIhIcg56ISHAMeiIiwTHoiYgEx6AnIhIcg56ISHAMeiIiwTHoiYgEx6AnIhIcg56ISHAMeiIiwTHoiYgEx6AnIhIcg56ISHD/C7++pXpuxF+jAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 481.6x198.66 with 1 Axes>"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bellIX.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:42.644760Z",
     "start_time": "2018-09-29T01:22:41.370675Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAUwAAACkCAYAAAD8DhcEAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAUgUlEQVR4nO3dfVBU570H8O8uerNFdlmyEI28eQFJ0QR2RcJFCWuMDUnVQGWITaqWEjWN/5TGODBN6tTSOAvoBKdx0lI7YAu0pbfNYGqjtopMRWSIuNh25k7Di6BWq3JZlhcTx93n/tGB60aEZ4Xdswvfz8yZwbPPOb8fun73OS+7qxJCCBAR0aTUSjdAROQvGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJIYmEREkhiYRESSGJhERJLmKN0AKaugoABWq9XrdY1GI8rLy71el2gqOMOc5axWq9cDU4maRNOBM0yC0WjE6dOnvVZv1apVXqtFNJ04wyQiksTAJC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wCQikvR/rXo6n0TAHgUAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 421.4x198.66 with 1 Axes>"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bellZI.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:43.840088Z",
     "start_time": "2018-09-29T01:22:42.647011Z"
    },
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAACkCAYAAACZ4+V7AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAVrklEQVR4nO3df1DT9/0H8GcAv0aUEIqIUkCHyKoiJELKsGqs2lKnjlqGbk4pZ622Xq9jooNbnWdL9QDtKd/W68bYoHfIbXSeouf541qRuwrkUhnQ2j9WCKJSrhZKCAV/3JLP9w+/MFMUEiGfhDfPx13uuE8+n7xefMRn3nnnnU8UkiRJICIiYXm5uwEiInItBj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeB83N0AuVdGRgbq6+tlr6vRaHDkyBHZ6xKNRxzRj3P19fWyB707ahKNZxzREzQaDS5duiRbvWXLlslWi4g4oiciEh6DnohIcAx6IiLBMeiJiATHoCciEhyDnohIcAx6IiLBjZugLykpcXr9dlxcHM6fP++ahsgtJEmCJEnuboNIVm4NeqvVit27dyMoKAh+fn5ISUlBR0eHx9ROTk7GqVOnZOlnLAkJCU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w8KF1Dhw4gGPHjuHq1asO9zZUbVfj1A0RjcRQswJj6qJmZrMZy5cvR01NDXp7e7F8+fJRm6MnIhLVmLpMsVqtRkZGBpYtWwYAeO+99xjyRETDGFMjeiIich6Hw0REgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeD+D7EEJHMjvYxCAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 481.6x198.66 with 1 Axes>"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bellXI.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:45.115744Z",
     "start_time": "2018-09-29T01:22:43.842944Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAacAAADRCAYAAABo433wAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAb1klEQVR4nO3deVRU990/8PeACjHMAAGicQEEJVVZZlhcEnlGBSUmEOqWBrdj3JJ4etRTwhmi/uFPox1cWmPaxnBoxCMSS6OJa8AalTYxThEK1phfWgVZctLKNgxigWS4zx+WeUQQBp258wXer3PuOeOd772fz3Bl3txl7igkSZJAREQkECdHN0BERPQghhMREQmH4URERMJhOBERkXAYTkREJByGExERCYfhREREwmE4ERGRcBhOREQkHIYTEREJh+FERETCYTgREZFwGE5ERCQchhMREQmH4URERMJhOBERkXAYTkREJByGExERCYfhREREwmE4ERGRcBhOREQkHIYT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BKVSiRUrVljOOR06dAivvfaaZfwTT9y7yqWsrKxXIbFjxw4cPnwYX3/9tdXLpKamor6+HlFRUWhpacGsWbOQlZVl9fKPg4f1iGig6e6IUZ+88WtmZiaqqqqwefNmR7dCRER20OfCacWKFTAYDGhpacH48eNx8uRJR7dEREQ21ufCiYiI+j/hbl9ERETEcCIiIuEwnIiISDgMJyIiEg7DiYiIhMNwIiIi4TCciIhIOAwnIiISDsOJiIiEw3AiIiLhMJyIiEg4DCciIhIOw4mIiITDcCIiIuEwnIiISDgMJyIiEg7DiYiIhMNwIiIi4TCciIhIOAwnIiISDsOJiIiEw3AiIiLhMJyIiEg4DCciIhLO/wJuVKktaw0zhgAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 541.8x258.86 with 1 Axes>"
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bellZZ.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:46.393088Z",
     "start_time": "2018-09-29T01:22:45.117743Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAdQAAADRCAYAAAB1nUNrAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAdNklEQVR4nO3df1RUZf4H8PcACbrMMCSkq/wwKFqVYEZEs6RRRCYTljWyolXXzKg8e8pd8wzV7h77oQ1qrdpWu6wbuKK5nJMdLAu1UnZLJZTA1D1txm+PLUgMg/IdqJn7/cN1cgJhBp+5MwPv1zn3nDnPPPc+H67Xec/9OQpJkiQQERHRNfHzdAFERERDAQOViIhIAAYqERGRAAxUIiIiARioREREAjBQiYiIBGCgEhERCcBAJSIiEoCBSk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ffhsLFizAihUr0NLSgqamJixfvlzoGEajEQkJCQN3/B+TyYTGxkYkJSXZ22JjY6FSqVBTUyO0NiIib6e7TWO/zzQocATSZiYNMAfJHqgXL17Eo48+ioKCAmRnZyMoKAhKpRJ6vd6p+dPS0hAeHo4XX3yx3355eXk4ceKE03V1dnYCAEJCQhza1Wo1zGaz08shIhoKAkdcB/3/bqNJm8nbZJwh+5OSysvLoVAokJWVNaj5i4qK8OGHH9rPcYqiVCoBAB0dHQ7tJpMJKpVK6Fh9ycsvcPsYRESD8d5HR/DeR0c8XYbXMBpy+2yXPVDPnz+P0NDQQZ/YjoiIEFzRJWq1GlFRUaiqqoJGowEA1NbWwmw2u3ToeLCu9g9ERORJkiTxQiQnyX7Id8qUKairq8O7774Lm80Gk8mEffv22d+3Wq2wWCzo6ekBAFgsFlgsFsjxhMTc3Fzk5+ejrq4OZrMZBoMBer0eEyZMcPvYRETeiGHqPNn3UOPj47F161Y89dRTyMnJgVKpxLJly+znULdv346HHnrI3n/kyJEAgLq6OpeCbd26ddixYwdOnTrl9Dx5eXlob29HcnIyuru7MXfuXBQXFzs9/7XgIV8iIt9wtSOKPvlw/KKiIjQ3N+N3v/udp0shIiIC4IOBumzZMlRUVKC7uxsTJ07Eu+++6+mSiIiIfC9QiYiIvJHXPXqQiIjIFzFQiYiIBGCgEhERCcBAJSIiEoCBSkREJAADlYiISAAGKhERkQAMVCIiIgEYqERERAIwUImIiARgoBIREQnAQCUiIhKAgUpERCQAA5WIiEgABioREZEADFQiIiIBGKhEREQCMFCJiIgEYKASEREJwEAlIiISgIFKREQkAAOViIhIAAYqERGRAAxUIiIiAf4fZnNCkTXgF/MAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 602x258.86 with 1 Axes>"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bellXX.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Let's begin by running just the first two questions, looking at the results of the first qubit ($q_0$) using a computational and then a superposition measurement."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:46.749149Z",
     "start_time": "2018-09-29T01:22:46.395377Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAE2CAYAAAADEMnHAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAgAElEQVR4nO3de5yWdZ3/8dcnTgILyCCLMykgQhOnaJRHZSqSpb9q132U+cvtYWrbuj7SysrKLX+ddIt+S1pav1rT3fXQwTXTytrl5yFYWQ/pigMLMs3CIvADRgJEQEEO4+f3x33DjuMA1w33HIDX8/G4H3Pf3+t7Xffncrx4z3X6XpGZSJKk/XtddxcgSdKhwtCUJKkgQ1OSpIIMTUmSCjI0JUkqyNCUJKkgQ1OSpIK6PDQj4vKIeDYiXo6IeRFx+n76942Ia8vzbI+IlRFxRbs+H4iIxeXpiyPi/Z27FpKkI1GXhmZEnA/cCMwAGoDHgFkRMXIfs/0T8G7gUqAe+J/Af7RZ5inAXcBPgDeXf94dEW/tjHWQJB25oitHBIqIJ4D/yMy/atO2BPh5Zn6xg/5nA3cDJ2bm+r0s8y6gJjPPatP2ELAuMz9U7XWQJB25enfVF0VEX+Bk4Lp2kx4A3r6X2d4H/DtwZURcBGwDZgFXZ+aL5T6nAN9rN9/9wCf2V9OwYcNy5Mh97eRKko408+fPX5+Zwzua1mWhCRwD9ALWtmtfC7xrL/OMAU4DtgMfAI6mFJB1wHnlPsfuZZnHdrTAiLiU0qFeamtrue66UobX1dUxYMAAli5dCsCQIUMYM2YMjY2NAPTq1YspU6bQ3NzMSy+9BMD48eN5/vnnWbu29PXHHXccffv2ZdmyZ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gETzzxBA8//DBPPPEEDz74YJeul3S42t8fubvdd9991NTU0NjYCMCOHTv4+Mc/zqmnnsrpp5/OI488sqfvPffcw6mnnsppp53Geeedx4YNGzp9PQ5lhuYRbN68eZxwwgmMHj2avn37cu655zJr1qxC886ePZvp06czdOhQjj76aKZPn85vf/tbBgwYwOmnnw5A3759edOb3sSaNWs6czWkI0LRP3K3bNnCD3/4Q04++eQ9bbuPED366KPce++9fPnLX+aVV15h165dfPGLX+S+++7jkUceYeLEidxyyy1dtk6HIkPzCNbS0sLrX//6PZ/r6upoaWl5Tb9f//rXnHbaaVx88cWsWrUKgDVr1rxm3vbhuGnTJu6//37OOOOMTloD6chR9I/cGTNm8KlPfYqjjjpqT1tzczPTpk0DYPjw4QwZMoTGxkYyk8xk69atZCZbtmzh2GOP7bJ1OhQZmtqnd7/73cyfP59HHnmEd7zjHXz84x8vNN+uXbu45JJLuPTSSxk9enTnFikdAYr8kbtgwQJWr17N2Wef/ar2iRMnMmvWLHbt2sWKFSuYP38+q1evpk+fPlx33XWceuqpTJgwgebmZi688MIuWZ9DlaF5BKutrWX16tV7Pq9Zs4ba2tpX9ampqaFfv34AXHjhhcyfPx8obbDt562rq9vz+dOf/jQnnngil112WWeugqSyV155hS996Ut8/etff820D3/4w9TV1XHmmWdy9dVX85a3vIVevXqxc+dObr31Vh5++GEWL17MxIkT+c53vtMN1R86DM0j2EknncSyZctYsWIFO3bs4N577+Xd7373q/o899xze97PmjWLN7zhDQCceeaZzJkzhxdeeIEXXniBOXPmcOaZZwLwjW98g82bNzNjxoyuWxnpMLe/P3JffPFFmpqaOOecc5gyZQpPPfUUF1xwAY2NjfTu3ZsZM2Ywd+5cfvKTn7Bp0yZOPPFEFi5cCMAJJ5xARPC+972PJ598ssvX7VDSu7sLUPfp3bs3M2fO5LzzzqO1tZULLriA8ePHM2PGDBoaGnjPe97DzTffzKxZs+jduzdDhw7l+9//PgBDhw7lc5/7HO985zsB+PznP8/QoUNZvXo1119/PePGjWP69OkAXH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4Eduxuy5P9l5t3An1IK1fO7qT5JHfsW8NGImFwO0NeIiGFdXNNhxdBUR5YBfwC+U74I6FX/n5SHL7wdeE93FCfptSLiQ5SOAl0P/Ar4VkS8PyJOjIj+5T79gX+IiMndWOohzcOz6lBEvI3SUITbKA1h+FtgY2a+GBEDgDuAlzPzw91YpqSyiLiF0gMsZgLnAhcDJwLNwL9Q2obrgRszs2931XmoMzS1VxExCfgy8GfAS5QG0F9H6VmlLcAlmbmw+yqUBBARvSkNJTo4M7/Qpn0ipb3P84CjgKOB2zPzL7ul0MOAoan9Kt9+8ifA+4CXKY3ve3dm/r5bC5O0R0QMBUZk5u8joi+ws+0FQRFxPnAncJIX8B04Q1MViYjXZeYr3V2HpP0rX48QmdkaEX9F6dDsgO6u61DW1Y8G0yHOwJQOHYxB8tUAAAA/SURBVO2210HAV7urlsOFe5qSdASIiD5Aq3/4HhxDU5KkgrxPU5KkggxNSZIKMjQlSSrI0JQkqSBDU5Kkgv4/azBvILZIa7sAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "circuits = [bellIZ,bellIX,bellZI,bellXI,bellZZ,bellXX]\n",
    "job = execute(circuits, backend)\n",
    "result = job.result()\n",
    "\n",
    "plot_histogram(result.get_counts(bellIZ))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:46.766640Z",
     "start_time": "2018-09-29T01:22:46.753801Z"
    }
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'0': 514, '1': 510}"
      ]
     },
     "execution_count": 12,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "result.get_counts(bellIZ)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "We find that the result is random. Half the time $q_0$ is in  $|0\\rangle$, and the other half it is in the $|1\\rangle$ state. You may wonder whether this is like the superposition from earlier in the tutorial. Maybe the qubit has a perfectly definite state, and we are simply measuring in another basis.  What would you expect if you did the experiment and measured in the superposition basis? Recall we do this by adding an $H$ gate before the measurement...which is exactly what we have checked with the second question."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:47.001529Z",
     "start_time": "2018-09-29T01:22:46.769186Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAE0CAYAAABO2GjMAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAfzklEQVR4nO3de5hV9X3v8fdXboIRnCEUZ2KAIIjcgqOcnBgDipZEbdPEy6P1aGLSJp7ERNt4kjRJbW4nsaekydF6zDHapmou1hqpubSccCKepGoSExymIpMpBIQiEzIiIgJyGb/nj70hwzgzrA17LsD79Tz7mb1/67d+813Ms/nstdZvrR2ZiSRJOrBj+rsASZIOF4amJEkFGZqSJBVkaEqSVJChKUlSQYamJEkFGZqSJBXU56EZEddGxJqIeCkilkbEnAP0HxoRnyuvszMi1kXE9Z36XBIRK8rLV0TERb27FZKko9HgvvxlEXE5cAtwLfBI+eeiiJiWmeu6We0fgJOAa4CVwFhgeIcxzwTuAz4NLAQuBu6PiLMy82c91TN69OgcN27coW2UJOmIsmzZsmczc0xXy6Iv7wgUET8D/i0z39ehbSXw7cz8RBf93wLcD5ycmc92M+Z9QG1mzu/Q9kOgLTOv6KmehoaGXLJkycFtjCTpiFRbW7s0M2d3tazPDs9GxFDgDGBxp0WLgTd1s9o7gJ8DN0TE+ohYGRF/ExGv6tDnzC7G/EEPY0qSdFD68vDsq4FBwMZO7RuB3+1mnYnAm4GdwCXACcCtQD1wabnPid2MeeKh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LNivbfPmzSxYsIAlS5YQEcybN48LLriAE044gR//+Mf7+s2bN4+3ve1tfbI9ktTb3NM8ii1dupTXve51TJgwgaFDh3LxxRezaNGiQusuWbKEc845h5qaGk444QTOOeccHnroof36rFq1ira2Ns4888zeKF+S+pyheRRrbW3lNa95zb7X9fX1tLa2vqLf9773Pd785jdz9dVXs379egA2bNjwinU3bNiw33oLFy7koosuIiJ6aQskqW8ZmurR+eefz7Jly3jkkUeYN28eH/zgBwuvu3DhQi655JJerE6S+paheRSrq6vjmWee2fd6w4YN1NXV7dentraWYcOGAfDOd76TZcuWAaU9y87r1tfX73u9fPly2tvbOe2003pzEySpTxmaR7HTTz+d1atXs3btWnbt2sXChQs5//zz9+vz61//et/zRYsWccoppwBw7rnn8vDDD/P888/z/PPP8/DDD3Puuefu6/vAAw9w8cUX982GSEeJA8123+u73/0utbW1NDY2ArBr1y4++MEPctZZZzFnzhweeeSRfX0vvfRS5syZw5lnnskNN9xAe3t7r2/H4czZs0exwYMHs2DBAi699FLa29u58sormTp1KjfddBMNDQ1ccMEF3HHHHSxatIjBgwdTU1PDbbfdBkBNTQ0f+chHOO+88wD46Ec/Sk1Nzb6xH3zwQe67775+2S7pSFR0tvvWrVv56le/yhlnnLGvbe+lYo8++ihtbW1cdtllPPTQQxxzzDF87WtfY+TIkWQmV199NQ8++KCnVXpgaB7l5s+fz/z58/dr++QnP7nv+ac+9Sk+9alPdbnuVVddxVVXXdXlsr2fcCVVR8fZ7sC+2e6dQ/Omm27iT/7kT7j11lv3tbW0tDB37lwAxowZw6hRo2hsbOSMM85g5MiRAOzZs4fdu3c7ce8APDwrSYeBIrPdm5qaeOaZZ3jLW96yX/v06dNZtGgRe/bsYe3atSxbtmy/OQmXXHIJp5xyCq961at4+9vf3rsbcpgzNCXpCPDyyy9z44038vnPf/4Vy6666irq6+s599xz+eQnP8kb3vAGBg0atG/5Aw88QHNzMzt37tzv5iR6JQ/PStJh4ECz3V988UWam5v33YHrN7/5DVdeeSXf/OY3a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+UIXfUZn5qY+L+4I4TlNdWUasAbYtbchS/4jM+8Hfp9SqF7eT/VJ6iQirqD0gfZLwHeAL0bERRFxckQML/cZDvxdRMzsx1IPa+5p6hXKb6zvAyOAdwG/ysyXO/W5DvjjzDytH0qU1ElE3EnpCywWABcDVwMnAy3AvwAPAVOAWzJzaH/VebhzT1OvkJk7gD8HhgP3AO+KiNdGxKsAImIEcDalWxZK6mcRMZjS0aHnM3N1Zv51Zs4E/hPwI0oB+o/ArcDX+6/Sw597mupWRMwA/gL4A2AbpW+daQN+l9JM2vdm5pP9V6GkvSKiBhibmb+MiKHA7o4TgiLicuBe4HTnIhw8Q1MHVL785PeAdwAvUdrDvD8zf9mvhUnqUUQcQ+n/+faIeB+lQ7Mj+ruuw5mhqYpExDGdz29KGvgi4gZgUGZ+sb9rOZwZmpJ0FIiIIUC7H3oPjaEpSVJBzp6VJKkgQ1OSpIIMTUmSCjI0JUkqyNCUJKkgQ1OSpIL+P8PAQ4S3rGFFAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "plot_histogram(result.get_counts(bellIX))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "In this case, we see that the result is still random, regardless of whether we measure in the computational or the superposition basis. This tells us that we actually know nothing about the first qubit. What about the second qubit, $q_1$? The next lines will run experiments measuring the second qubit in both the computational and superposition bases."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:47.382298Z",
     "start_time": "2018-09-29T01:22:47.006601Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAE2CAYAAAADEMnHAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpY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/eUm/7du387WvfY3TTjvtQNv+cyUPPPAACxYs4BOf+AQvvPACI0eO5L777jvwOumkk3jrW9/aa9skDWTnn38+y5cv5/777+ess87iAx/4QKH15s+fT1NTE7t37+a+++7r4SqPbobmAFZ0uueGG27gQx/6EMcdd9yBtubmZubOnQtAbW0to0ePPnAUut/q1atpbW3l9NNP79kNkQaAuro6nnjiiQOfN27cSF1d3Yv61NTUMHToUADe9a53sXz5cqB0ZNlx3fr6+hete9xxx3HBBRcUnvIdqAzNAazIdE9jYyNPPPEE55133ovap0+fzsKFC9m3bx/r1q1j+fLlL9opARYsWMCFF17oORKpAk499VTWrFnDunXr2LNnDwsWLOD8889/UZ8nn3zywPuFCxdyyimnAHD22WezZMkSnn32WZ599lmWLFnC2WefzXPPPXdgnX379rFo0SImT57cext1FPLqWXXphRde4Prrr+crX/nKS5a9853v5Le//S1nn302J510Eq997Wupqqp6UZ8FCxZw880391a50jFt0KBBzJs3j0suuYS2tjYuu+wypk6dyg033EBDQwNvectbuOWWW1i4cCGDBg2iurr6wL5bXV3Nhz/8Yc455xwAPvKRj1BdXc1TTz3FZZddxu7du3nhhReYM2cOV155ZV9uZr8XmdnXNfSZhoaGXLx4cV+X0WcefvhhPvvZzzJ//nwAvvSlLwFw7bXXArBt2zZOPfVURowYAcBTTz1FdXU13/rWt2hoaHjRWG9+85u56aabDlz+vmLFCq688kp+9atf9dbmSFJF1NTULM3M2Z0tc3p2ADvUdM+oUaNYvXo1jY2NNDY2Mnv27AOBuXPnTnbs2AHAkiVLGDRo0IvuF5s/fz4XXXRRr2+TJPUkp2cHsCLTPV15+umnueSSS4gI6uvrXzINe++993L33Xf39CZIUq9yenYAT89Kkl7K6VlJkirA0JQkqSBDU5KkggxNSZIKMjQlSSrI0JQkqSBDU5KkggxNSZIKMjQlSSrIx+hJGnA+ent1X5egHjDvii09/jM80pQkqSBDU5KkgpyerQCneo5NvTHVI+no4pGmJEkFGZqSJBVkaEqSVJChKUlSQYamJEkFGZqSJBVkaEq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g4E2/9N7ZAxNSZIK8upZSZIKMjQlSSrI0JQkqSBDU5KkggxNSZIKMjQlSSro/wOs7U+39QXofwAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "plot_histogram(result.get_counts(bellZI))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAEyCAYAAACYgYvRAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAfh0lEQVR4nO3de3hddZ3v8feX0JYW29LUTEmtaa2tMb0QQzlCUS4eRBEPPgooKgfRUTmKgCNndPQMM+pc8Ey9gR6Vy1y4qDMMijccjojlyAgqUkKG0hhbS9spjTWktZS2tCV+zx97F0NI0rXbnUvb9+t59pO9f+u3fvku8ux+WLffisxEkiTt3WEjXYAkSQcKQ1OSpIIMTUmSCjI0JUkqyNCUJKkgQ1OSpIIOH+kCRtLUqVOzoaFhpMuQJI0iDz300OOZWdffsmEPzYi4GPgwUA88AvxJZv77IP3HAlcAFwDTgY3AZzLzC736nAP8NfBi4NfAn2fmt/ZWS0NDA0uXLt2PrZEkHWxqa2vXDrRsWA/PRsR5wNXAlUALcB9wR0QMtrv3L8AZwEVAI/Bm4D96jbkYuAX4GvCy8s9bI+L4odgGSdKhK4ZzRqCI+DnwH5n53l5tK4FvZObH+un/GuBW4MWZ+fgAY94C1Gbm6b3a7gK6MvNtg9XT0tKS7mlKknqrra1dlpnH9bds2PY0y4dZFwF39ll0J3DiAKu9EfgFcHlErI+IlRHxhYh4Xq8+i/sZ8weDjClJ0j4ZznOazwdqKJ2T7G0j8OoB1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SmN7FkyZLnrH/ppZeyY8cObrjhhme1H3/88bz2ta/lrLPOGsryDxruaUrSAWDZsmW86EUvYtasWYwdO5azzz6bO+64o/D6p5xyCs973vOe037MMcfQ0NDQzxrqj6EpSQeAzs5OXvCCFzzzefr06XR2dj6n3/e+9z1e+cpXcuGFF7J+/frhLPGQYGhK0kHijDPO4KGHHuInP/kJr3rVq/jABz4w0iUddAxNSToA1NfX89hjjz3zecOGDdTX1z+rT21tLePGjQPgggsu4KGHHhrWGg8FhqYkHQCOPfZYVq9ezdq1a9m1axe33XYbZ5xxxrP6/OY3v3nm/R133MFLXvKS4S7zoGdoStIB4PDDD2fJkiWce+65nHDCCbzxjW+kqamJK6+88pkLgq677joWL17MSSedxHXXXceXvvSlZ9Y/88wzede73sU999zD/Pnz+dGPfgTAtddey/z589mwYQMnnXQSl1122Yhs34EiMnOkaxgxLS0tuXTp0pEuQ5I0itTW1i7LzOP6W+aepiRJBRmah7i9zTCyx3e/+11qa2tpbW0FYPfu3Vx88cW84hWv4Pjjj+fzn//8M32vueYaTjzxRBYvXsxXvvKVId8GSRouzgh0CCs6w8jWrVu59tprWbRo0TNt3/nOd9i5cyf33nsv27dvZ/HixZxzzjk8+eST3HTTTdx1112MHTuWN7/5zbz2ta9l9uzZw715klR17mkeworOMHLllVfywQ9+kCOOOOKZtohg+/btPP300zz11FOMHTuWiRMn8qtf/YpFixYxYcIEDj/8cE488URuv/324dwsSRoyhuYhrMgMI21tbTz22GO85jWveVb7G97wBiZMmEBTUxPHHHMMH/jAB5gyZQpNTU387Gc/Y9OmTWzfvp0f/vCHz7q3TJIOZB6e1YB+//vfc8UVVzzrsvU9li1bRk1NDStWrOB3v/sdr3/96zn11FNpbGzksssu45xzzmHChAksXLiQww7z/80kHRz81+wQtrcZRp588kna29s566yzaG5u5oEHHuD888+ntbWVb37zm5x22mmMGTOGuro6Xv7ylz9zkdAFF1zA3Xffzfe//32OOuoo5syZM+zbJklDwdA8hO1thpFJkyaxatUq2traaGtr47jj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0fEmyLixRExvtxnPPAPEbFwBEs9oLmnqecof7FuByYA7wB+nZm/79PnUuDdmfmyEShRUh8RcT2lB1gsAc4GLgReDHQA/wb8CGgErs7MsSNV54HOPU09R2buAP4cGA/cBLwjIl4YEc8DiIgJwCmUpiyUNMIi4nBKR4d+l5mrM/MzmbkQ+C/AjykF6L8CXwRuHrlKD3zuaWpAEbEA+AvgDcA2Sk+d6QJeTelK2vdk5sMjV6GkPSJiCjAtM38ZEWOB3b0vCIqI84B/Bo71WoR9Z2hqr8q3n7weeCPwFKU9zFsz85cjWpikQUXEYZT+ne+JiPdSOjQ7YaTrOpAZmqpIRBzW9/ympNEvIi4HajLz0yNdy4HM0JSkQ0BEjAF6/J/e/WNoSpJUkFfPSpJUkKEpSVJBhqYkSQUZmpIkFWRoSpJUkKEpSVJB/x9Bzh/GWSv6IwAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "plot_histogram(result.get_counts(bellXI))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Once again, all the experiments give random outcomes. It seems we know nothing about either qubit in our system! In our previous analogy, this is equivalent to two readers separately reading a quantum paper and extracting no information whatsoever from it on their own.\n",
    "\n",
    "What do you expect, however, when the readers get together?  Below we will measure both in the joint computational basis. "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:47.590775Z",
     "start_time": "2018-09-29T01:22:47.385718Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAE/CAYAAAAkH5gPAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliL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m6ezFyemd8HzqS0q/Yvu6g+SS1ExHuBvwOupzQRyZcj4qyIOLJ8jHPnsc7bd14+pj3nlqZepvzh+ikwiNKsP39oPUVeedKDv83M13dBiZJaiIhbKM3SNRU4G7gIOBJYBPw78AtgLHBjZvbrqjp7Crc09TKZucK9W0QAAADuSURBVBn4B2AgcAdwYUQcFhGvgl0nE5wMLOi6KiUBREQfSnuGNmTm0sz8SmYeA7wB+CWlAP0+8HXgzq6rtOdwS1NtKu/G+SzwF5Qman8YWAu8HWgELs7MJ7quQkkAETEMGJmZvyvP2LWt5QlBEXEecBdwbGY+3lV19hSGpjpUvvzkz4B3U5oybwHwg8z8XZcWJqld5Vm7IjObI+LvKO2aHdTVdfUEhqYK8xZg0v4nIq4AajLzy11dS09gaEpSDxYRfYFmv/BWhqEpSVJBnj0rSVJBhqYkSQUZmpIkFWRoSpJUkKEpSVJBhqYkSQX9Nz7Hq29E2REsAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "plot_histogram(result.get_counts(bellZZ))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Here we see that with high probability, if $q_0$ is in state 0, $q_1$ will be in 0 as well; the same goes if $q_0$ is in state 1. They are perfectly correlated.\n",
    "\n",
    "What about if we measure both in the superposition basis?  "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:47.802764Z",
     "start_time": "2018-09-29T01:22:47.594050Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAE6CAYAAAB00gm8AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYX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hmlyOiiBgBXAx8sz9qGyw80tSzRMRtwHTgR8CTlE7NzgReCPwBuD4zvSYiDRDlEbHbugZllz7HUhoo9I/lZxHrIBiaeoby/6Vuo3QKZ2GntgnAyyldF5kMvCEzF/dboZL2i4ivUxo1+xCwJjO3dtPnhMz8Y58XN8g4elZdTQMepTJmfRMAAAFpSURBVHS7CVA6zZOZazLze8AFlE7V/lU/1Sepk4h4E/Bu4POUJiL5bERcGBEvKF/j3Het81v7bh/TwfNIU89Q/nL9GBhBadaf33edIq886cE7M/Ml/VCipE4i4lZKs3TdCFwEvA14AdAG3Av8FGgAbsrMof1V52DhkaaeITN3Av8DGA7cDlweEc+PiONh/2CCM4Gl/VelJICIOIbSmaE/ZuaqzPxcZs4EXgr8G6UA/R7wFeCO/qt08PBIU90qn8b5O+B1lCZq/xWwETgHaAfelZlL+q9CSQARMQYYl5m/K8/YtbfzgKCIuBT4R+CUzHykv+ocLAxN9ap8+8lfAq+nNGXeUuD7mfm7fi1MUo/Ks3ZFZnZExLspnZod0d91DQaGpgrzEWDSkScirgNqMvOz/V3LYGBoStIgFhFDgA7/h7c6DE1Jkgpy9KwkSQUZmpIkFWRoSpJUkKEpSVJBhqYkSQUZmpIkFfT/AVgv7SrgEfqYAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "plot_histogram(result.get_counts(bellXX))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Here we see that the system **also** has perfect correlations (accounting for experimental noise). Therefore, if $q_0$ is measured in state $|0\\rangle$, we know $q_1$ is in this state as well; likewise, if $q_0$ is measured in state $|+\\rangle$, we know $q_1$ is also in this state. These correlations have led to much confusion in science, because any attempt to relate the unusual behavior of quantum entanglement to our everyday experiences is a fruitless endeavor. \n",
    "\n",
    "Finally, we need to point out that having correlated outcomes does not necessarily imply that what we are observing is an entangled state. What would we observe, for example, if we prepared half of our shots in the $|00\\rangle$ state and half of the shots in the $|11\\rangle$ state? Let's have a look"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:49.085422Z",
     "start_time": "2018-09-29T01:22:47.807163Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAUwAAADRCAYAAACn4Yt2AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAVyUlEQVR4nO3df0zTd/4H8CeIwk5aioJyihRBvakLtPJlTPfdqsjGNvGLjJhvvCljhuPuWMKZca7cttwtuRtXdCYsi/tmnVPckBjiLl8kx9Bchty+y9nLgWD0u91OKUXuu0VBahUPmPX9/cOjN8avd6H9fKh9PpJPUj99v/t6FcuTz6+2IUIIASIimlKo2g0QEQUKBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkSQGJhGRJAYmEZEkBiYRkaQwtRug+9eePXvQ3t6ueF2DwYCqqirF69L9j1uY5Dft7e2KB6YaNSl4cAuT/MpgMODMmTOK1du4caNitSj4cAuTiEgSA5OISBIDk4hIEgOTiEgSA5OISBIDkwKa0+lUuwUKIgxMUp0QAs3NzSgtLcWjjz6KRYsWYcGCBVi+fDny8vKwf/9+fP3112Pmtba2Ijk5GcePH1ehawpGQROY1dXVXl+jl5aWhlOnTvmnIQIANDY2Yu3atcjMzMT777+P0NBQ5OXl4bnnnkNGRgYuXryIl19+GcuWLUNhYSF6e3sB3AvLrKwsaLVaPPLIIyo/CwoWqgam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aIKEgEXGASEall1r01kohotmJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUliYBIRSWJgEhFJYmASEUn6f/49Cm2tdZOSAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 421.4x258.86 with 1 Axes>"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# quantum circuit to make a mixed state \n",
    "mixed1 = QuantumCircuit(q2, c2)\n",
    "mixed2 = QuantumCircuit(q2, c2)\n",
    "mixed2.x(q2)\n",
    "mixed1.measure(q2[0], c2[0])\n",
    "mixed1.measure(q2[1], c2[1])\n",
    "mixed2.measure(q2[0], c2[0])\n",
    "mixed2.measure(q2[1], c2[1])\n",
    "\n",
    "mixed1.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:50.238478Z",
     "start_time": "2018-09-29T01:22:49.087602Z"
    },
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAADRCAYAAADCDHkJAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAYa0lEQVR4nO3dfVBTZ9oG8CuAixYSQgFFpYDA2lZdDFJKpWpQUNaKgx/Vrbqw6Lo4i52Oo7Jh7Hamw1YbqFjszn6UcStWcKyWHSNTCu2OyvjWbjotBYdud9ouCPL6AbhgkBXBcN4/fM2KfCVITpKH6zdzZuLJc3LfOZ5cc/LkJCgkSZJARETCcnN0A0REZF8MeiIiwTHoiYgEx6AnIhIcg56ISHAMeiI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t8fX2hUAx9qdRwgoKCxrije9RqNYKDg1FdXQ2N5t71uPX19TCZTDZNAY3WcP9JRNSfJEmjzpDxSPapm3nz5qGhoQFlZWXo6+tDR0cHKisrLfebzWZ0d3ejp6cHANDd3Y3u7m7I8UsNGRkZyM3NRUNDA0wmE3Q6HZKSkhAaGmr32kRkPYa8bWQ/o58zZw4OHTqE3bt3Y8OGDVAqldiyZYtljv7o0aPYvHmzZfykSZMAAA0NDTYF7r59+1BSUoJvvvnG6m2ys7PR3t6OmJgY3LlzB0uXLkVxcbHV2z8KTt0Q0aMYblbAJX/UrKioCM3Nzfjtb3/r6FaIiJyeywX9li1bYDQacefOHTz99NMoKytzdEtERE7N5YKeiIhsw+8NExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgmPQExEJjkFPRCQ4Bj0RkeAY9EREgvs/Pe24QHIMu0cAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 481.6x258.86 with 1 Axes>"
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "mixed2.draw(output='mpl')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-09-29T01:22:50.594107Z",
     "start_time": "2018-09-29T01:22:50.241472Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAFACAYAAADeaycbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAfJElEQVR4nO3de5SddX3v8feX3EgwkJmYhhkhxJAQA6RxIF64y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lQz43AYsoBeVJwD8AMzNz1QCUKaksIpqA9wDLMvPeLstagA+WlzcAh2bmM7Wvct9naKpXETEOmAQcD5xN6VwIlJ5XGsCdmXnNwFQnqbOIGA1kZm7vfHFelv+hj4jPAGdlZstA1biv8z5NvUZE/BbwPuAvKD3sexulw7APAZ8DRlA6Z/LvmfmLgapT0qtl5rbdYZld9ogiYgzwbuCrA1HbYOGepl4jIm6j9Ci27wPPUTo0OxM4AvgV8MnM9JyIVCfKV8Ru6RqUXfrsT+lCobsys71mxQ0yhqZepfy/1C2UDuE82KltEvA2SudFpgDnZebjA1aopFdExFcoXTX7KLA6M1/sps+4zHy+5sUNMl49q66OBJ6mdLsJUDrMk5mrM/ObwO9ROlT7BwNUn6ROIuK9wJ8Cn6c0Ecn1EXF2RBxePse5+1zn7btvH1PfuaepVylvXD8AxlCa9eeXXafIK0968CeZ+eYBKFFSJxFxK6VZuuYB5wAXAYcDrcAPgR8B04EbM3PkQNU5WLinqVfJzG3AXwKjgTuACyPi0Ih4HbxyMcHJwJKBq1ISQEQMp3Rk6PnMXJmZn8vMmcBbgB9TCtBvAl8C7hy4SgcP9zTVrfJhnL8Cfp/SRO0/ATYCc4A24IOZ+eTAVSgJICIagImZ+d/lGbt2dr4gKCLOB+4CjsnMJwaqzsHC0FSvyref/A7wLkpT5i0BvpWZ/z2ghUnqUXnWrsjMjoj4U0qHZscMdF2DgaGpwnwEmLTviYgrgGGZef1A1zIYGJqSNIhFxAigw//wVoehKUlSQV49K0lSQYamJEkFGZqSJBVkaEqSVJChKUlSQYamJEkF/X9FDpXBHIvGjwAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 504x360 with 1 Axes>"
      ]
     },
     "execution_count": 20,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "mixed_state = [mixed1,mixed2]\n",
    "job = execute(mixed_state, backend)\n",
    "result = job.result()\n",
    "\n",
    "counts1 = result.get_counts(mixed_state[0])\n",
    "counts2 = result.get_counts(mixed_state[1])\n",
    "\n",
    "from collections import Counter\n",
    "ground = Counter(counts1)\n",
    "excited = Counter(counts2)\n",
    "plot_histogram(ground+excited)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "We do see the same kind of correlation indeed as we observed in the \"bell_measureZZ\" circuit. But we know this is not an entangled state! All we have done is leave the qubits in their ground state for some of the shots and flip both qubits for some of the shots. This is called a mixed state and it is a classical state. Now, would we observe a similar outcome if we measured this mixed state in the superposition basis? We will leave this for the reader to try.\n",
    "\n",
    "This is just a taste of what happens in the quantum world with multi-qubit states. Please continue to [Testing Entanglement](entanglement_testing.ipynb) to explore further!"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "anaconda-cloud": {},
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
